package com.freesaas.merchant.interceptor;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import org.springframework.stereotype.Component;
import org.springframework.web.servlet.handler.HandlerInterceptorAdapter;

import com.fast.common.util.ApplicationUtil;

@Component(value="baseInceptor")
public class BaseInterceptor extends HandlerInterceptorAdapter {

	@Override
	public boolean preHandle(HttpServletRequest request, HttpServletResponse response, Object handler)
			throws Exception {
		request.setAttribute("base", ApplicationUtil.getValue("BASE_URL"));
		return super.preHandle(request, response, handler);
	}
}
